﻿using wscf.lightblue.Build;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;
using System.Diagnostics;
using System.IO;

namespace wscf.lightblue.Test
{
	[TestClass()]
	public class InvokeVisualStudioToolTest : ActivityBaseTest
	{
		[TestMethod()]
		public void ExecuteTest()
		{
			InvokeVisualStudioTool target = new InvokeVisualStudioTool
			{
				Name = "ExecuteTest",
				FileName = "csc",
				Arguments = "/?"
			};
			target.Execute();
			Assert.IsFalse(target.IsError);
		}

		[TestMethod()]
		public void ExecuteFailTest()
		{
			InvokeVisualStudioTool target = new InvokeVisualStudioTool
			{
				Name = "ExecuteTest",
				FileName = "svcutil",
				Arguments = "Does_not_exist"
			};
			target.Execute();
			Assert.IsTrue(target.IsError);
		}

	}
}
